package org.ohos.sample.cordova;

import ohos.agp.components.webengine.WebView;
import ohos.app.Context;

public abstract class WebViewEngine {

    private Context mContext;
    protected WebViewInterface webViewInterface;
    public WebViewEngine(Context context,WebViewInterface webViewInterface){
        mContext = context.getApplicationContext();
        this.webViewInterface = webViewInterface;
    }

    public final  Context getContext(){
        return mContext;
    }
    public abstract void init(WebView webView);

    public abstract void load(String url);

    public abstract boolean canGoBack();

    public abstract void goBack();

    public abstract void goForward();

    public abstract boolean canGoForward();

    public abstract void destroy();

}
